/**
 * Created with IntelliJ IDEA.
 * Description:
 * User: 28779
 * Date: 2023-03-18
 * Time: 16:43
 */

class information{
    private int age;
    private String name;

    public void setName(String name){
        this.name = name;
    }
    public String getName(){
        return this.name;
    }
    public void setAge(int age){
        this.age = age;
    }
    public int getAge(){
        return this.age;
    }
    public void print(){
        System.out.println("姓名是: " + this.name + " 年龄是: " + this.age);
    }
    //-------------------------------------------------------------------------------
}
public class Student {
    public static void main(String[] args) {
        information d = new information();
        d.setName("zhangzhaohan");
        d.setAge(10);
        System.out.println(d.getName());
        System.out.println(d.getAge());
        d.print();
    }
}
